package Chapter02.Homework.H20211110;
import java.text.SimpleDateFormat;
import java.util.Calendar;
import java.util.Date;

public class Work00 {
    public static void main(String[] args) {
        Date date=new Date();
        SimpleDateFormat sdf=new SimpleDateFormat("yyyy年MM时dd分");
        System.out.println("当前时间："+sdf.format(date));
        Calendar c=Calendar.getInstance();
        int zhi=c.get(Calendar.DAY_OF_WEEK);
        switch (zhi){
            case 1:
                System.out.print("周日");
                break;
            case 2:
                System.out.print("周一");
                break;
            case 3:
                System.out.print("周二");
                break;
            case 4:
                System.out.println("周三");
                break;
            case  5:
                System.out.println("周四");
                break;
            case 6:
                System.out.println("周六");
                break;
        }
    }
}
